\documentclass{standalone}
\usepackage{tikz}
\usepackage{ctex,siunitx}
\setCJKmainfont{Noto Serif CJK SC}
\usepackage{tkz-euclide}
\usepackage{circuitikz}
\usepackage{amsmath}
\usetikzlibrary{patterns, calc}
\usetikzlibrary {decorations.pathmorphing, decorations.pathreplacing, decorations.shapes}
\ctikzset{bipoles/length=1cm}
\begin{document}
\small
\begin{circuitikz}[>=latex,scale=1.0,european]
  % \useasboundingbox(-2,-2.2)rectangle(2,1.5);
  \foreach \x in {1}
  {
    \foreach \y in {-1,0,1}
    {
      \fill[inner color=white, outer color= red!30](0.5*\x-0.25,0.5*\y)circle(3pt)node{\tiny$+$};
      \fill[inner color=white, outer color= blue!30](-0.5*\x+0.25,0.5*\y)circle(3pt)node{\tiny$-$};
    }
  }
  \draw(-2.5,-0.75)rectangle(2.5,0.75)(0,-0.75)--(0,0.75);
  \node at (-1.5,0){P};
  \node at (1.5,0){N};
  \draw[thin,densely dashed](-0.5,1.3)--(-0.5,-0.75)(0.5,1.3)--(0.5,-0.75);
  \node at (0,1.0) {变薄};
  \node at (0,1.4) {阻挡层};
  \draw[->](0.5,-1.1)--(-0.5,-1.1)node[at start,right]{阻挡层电场};
  \draw[<-](0.5,-1.5)--(-0.5,-1.5)node[at end,left]{外电场};
  \draw(-2.5,0)--(-3,0)--(-3,-3)to[battery,name=dc](3,-3)to[R=$R$](3,0)--(2.5,0);
  \node at(dc.left)[below left]{$+$};
  \node at(dc.right)[below right]{$-$};
  \draw[->](-3,-3)--(-3,-1.5)node[left]{$I$};
  \end{circuitikz}
\end{document}